import { httpUrl } from 'api/config'
import { ajax } from 'api/axios'

export const getUserWxAutoLogin = (isTenantLogin) => {
  let url = ''

  if (isTenantLogin) {
    url = `${httpUrl}/rentor/wxAutoLogin`
  } else {
    url = `${httpUrl}/wxAutoLogin`
  }

  const data = {
    openId: wx.getStorageSync('openid')
  }

  return ajax(url, data)
}

export const getFirstImg = () => {
  const url = `${httpUrl}/firstImage `

  const data = {}

  return ajax(url, data)
}
